home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Almathera Ten Pack 3: CDPD 3
/
Almathera Ten on Ten - Disc 3: CDPD3.iso
/
scope
/
151-175
/
scopedisk168
/
asmmacros
/
am_02
/
getprefs.i
< prev
next >
Wrap
Text File
|
1995-03-19
|
1KB
|
50 lines
NOLIST
GetPrefs MACRO ; 14 Sept 88
*------------------------------; Start of GetPrefs macro.
NOLIST
IFC '\1','D' ; If <BufferStartAddr> is specified, then
LIST
; Make A0 point to the start of the buffer.
MOVE.L #\2,A0
NOLIST
IFEQ NARG-2 ; If <BufferSize> is given, then
LIST
; Put <BufferSize> in D0.
MOVE.L #\3,D0
NOLIST
ENDC
IFEQ NARG-2 ; If there is no third argument, then
LIST
; Calculate buffer size as
; <BufferStartAddr>End minus
; <BufferStartAddr>. Put it in D0.
MOVE.L \2End-\2,D0
NOLIST
ENDC
ENDC
IFNC '\1','I' ; If <MemBlockName> is specified, then
LIST
; Get the buffer start address from
; <MemBlockName>.Adr , and get the buffer
; Size from <MemBlockName>.Size
NOLIST
IFEQ ReEntrant-1
LIST
MOVE.L \2.Adr(A5),A0
MOVE.L \2.Size(A5),D0
NOLIST
ENDC
IFNE ReEntrant-1
LIST
MOVE.L \2.Adr,A0
MOVE.L \2.Size,D0
NOLIST
ENDC
ENDC
LIST
; Call GetPrefs.
CallLib GetPrefs,intuition
*------------------------------; End of GetPrefs macro.
ENDM
LIST